def my_decorator(func):  
    def wrapper():  
        print("函数执行前")  
        func()  
        print("函数执行后")  
    return wrapper  
  
@my_decorator  
def say_hello():  
    print("Hello!")  
  
say_hello()